<?php
/**
 * Created by PhpStorm.
 * User: liandne
 * Date: 2016/12/12
 * Time: 上午11:13
 */
namespace App;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;

/**
 * App\DocHug
 *
 * @property integer $id 标识
 * @property integer $doc_id 关联医生id
 * @property string $hugh_date 休息日期
 * @property integer $hugh_slot 休息时间段(0:没有休息时段 1-6：1-6时段)
 * @property integer $limit_bespeak 限制预约数
 * @property string $deleted_at
 * @property \Carbon\Carbon $created_at
 * @property \Carbon\Carbon $updated_at
 * @property-read \App\Doctors $doctor
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereId($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereDocId($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereHughDate($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereHughSlot($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereLimitBespeak($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereDeletedAt($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereCreatedAt($value)
 * @method static \Illuminate\Database\Query\Builder|\App\DocHug whereUpdatedAt($value)
 * @mixin \Eloquent
 */
class DocHug extends Model {

    protected $table = 'doc_hug';
    use SoftDeletes;

    /**
     * 医生表关联
     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
     */
    public function doctor(){
        return $this->belongsTo('App\Doctors','doc_id');
    }
}
